From: Keir Fraser Date: Wed, 29 Oct 2008 16:58:05 +0000 (+0000) Subject: cpufreq.c: shut up compiler about cpufreq_dom X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~14054^2~13 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=684173fed1386c7ac5243dbabdc25fa5585c9700;p=xen.git cpufreq.c: shut up compiler about cpufreq_dom Some versions of GCC are too stupid to figure out that cpufreq_dom is only used if !!domexist and always set in that case, and complain that it may be used uninitialised. Signed-off-by: Ian Jackson --- diff --git a/xen/drivers/cpufreq/cpufreq.c b/xen/drivers/cpufreq/cpufreq.c index eb88e1744b..7020ad50a1 100644 --- a/xen/drivers/cpufreq/cpufreq.c +++ b/xen/drivers/cpufreq/cpufreq.c @@ -80,7 +80,7 @@ int cpufreq_add_cpu(unsigned int cpu) unsigned int dom, domexist = 0; unsigned int j; struct list_head *pos; - struct cpufreq_dom *cpufreq_dom; + struct cpufreq_dom *cpufreq_dom = NULL; struct cpufreq_policy new_policy; struct cpufreq_policy *policy; struct processor_performance *perf = &processor_pminfo[cpu]->perf;